
package com.ebbinghaus.review;

import org.springframework.data.redis.core.RedisTemplate;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * @description: TODO
 * @author charles
 * @date 2019/4/97:18
 */

@RestController
@RequestMapping(value = "login")
public class LoginController {

    @Resource
    private RedisTemplate<String, String> redisTemplate;


    @RequestMapping(value = "/test")
    public String testApi(){
        this.redisTemplate.opsForValue().set("study", "java");
        System.out.println(this.redisTemplate.opsForValue().get("study"));
        return "success";
    }
}
